package com.hxzy.shop.utils;

import com.alibaba.fastjson.JSONObject;
import org.springframework.http.HttpEntity;
import org.springframework.http.HttpHeaders;

import java.util.Map;

/**
 * 功能描述: 微信企业营销通需 要传递的头
 *
 * @author tonneyyy
 */
public class WeixinYxtUtil {

    public static HttpEntity<String> getHttpEntity(Map<String, String> prams) {
        HttpHeaders headers = new HttpHeaders();
        headers.add("Content-Type", "application/json;charset=UTF-8");
        headers.add("x-logw-modular", "open");
        headers.add("x-logw-client", "third");
        headers.add("x-logw-version", "2.0");
        String str = JSONObject.toJSONString(prams);
        HttpEntity<String> request = new HttpEntity<>(str, headers);
        return request;
    }

}
